//
//  VillageQViewModel.m
//  Village
//
//  Created by longrise on 2017/11/14.
//  Copyright © 2017年 程虎. All rights reserved.
//

#import "VillageQViewModel.h"

@implementation VillageQViewModel
+ (void)DemandMessageWith:(NSString *)Villareaid Villorgcod:(NSString *)Villorgcod Success:(void (^)(NSArray *valueDict))success failure:(void (^)(NSString *error))failure{
    
    NSMutableDictionary *entitybean = [NSMutableDictionary dictionary];
    NSMutableDictionary *dict = [NSMutableDictionary dictionary];
    if ([Villareaid isEqualToString:@""]){
        
    }else{
        [dict setObject:Villorgcod forKey:@"orgcode"];
        [dict setObject:Villareaid forKey:@"areaid"];
    }
  
    [entitybean setValue:dict forKey:@"entitybean"];
    
    [NetRequestClass Post:searchPovareaidURL Parameters:entitybean success:^(id result) {
        if (success) {
            success(result[@"data"]);
        }
    } failure:^(id valueCode, id error) {
        if (failure) {
            failure(error);
        }
    }];
    
}
@end
